#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include <math.h>
int main()
{
	int n = 0;
	scanf("%d", &n);
	double a = 0;
	int i = 0;
	int sign = 1;
	int count = 0;
	float k = 0;
	for (i = 1; i <= 2 * n - 1; i += 2)
	{
		if (sign == -1)
		{
			count -= i;
			sign += 2;
		}
		else
		{
			count += i;
			sign -= 2;
		}
		k += 1.0 / count;
	}
	printf("%.3f", k);
	return 0;
}
#include <stdio.h>
int main()
{
	int n = 0;
	scanf("%d", &n);
	int i = 0;
	double count = 0.0;
	for (i = 1; i <= n; i++)
	{
		count += 1.0 / i;
	}
	printf("%.6lf", count);
	return 0;
}
#include <stdio.h>
#include <math.h>
int main()
{
	int n = 0;
	scanf("%d", &n);
	int i = 0;
	int count = 0;
	for (i = 1; i <= n; i++)
	{
		count += (int)pow(-1, i + 1)*i;
	}
	printf("%d", count);
	return 0;
}